package cn.team.mapper;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import cn.team.entity.User;

@Mapper
@Repository
public interface UserMapper {
    User getUser(@Param("username") String username);
    int registerUser(@Param("username") String username, @Param("password") String password,@Param("portraitName")String portraitName);
    User getUserById(@Param("id")int id);

    int updatePortrait(@Param("portrait") String portrait,@Param("username")String username);

    int updateUser(@Param("username")String username,@Param("petName")String petName,@Param("email")String email,
                   @Param("phone")String phone,@Param("gender")String gender,@Param("age")Integer age);
    int updatePassword(@Param("username")String username,@Param("rpassword")String rpassword);
}
